package cn.tedu.boot51.mapper;

import cn.tedu.boot51.entity.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;


/**
 * @Classname: UserMapper
 * @Author: bromide
 * @CreateTime: 2022/5/16--10:46
 * @Version: V1.0
 * @Description:
 */
@Mapper
public interface UserMapper {
    @Select("select * from user where username=#{username}")
    User selectByName(String username);

    @Insert("insert into user values(null,#{username},#{password},#{nickname})")
    void insert(User user);
}
